package com.wang.cloud.manage.domain.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.wang.cloud.common.mysql.domain.entity.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import java.time.LocalDateTime;

/**
* <p>
* 系统平台用户信息表
* </p>
*
* @author wy
* @since 2024-07-16
*/
@Getter
@Setter
@TableName("sys_platform_user")
@Schema(name = "PlatformUserEntity", description = "系统平台用户信息表")
public class PlatformUserEntity extends BaseEntity {

    @Schema(description = "平台id")
    @TableField("platform_id")
    private String platformId;

    @Schema(description = "用户账号")
    @TableField("user_name")
    private String userName;

    @Schema(description = "手机号码")
    @TableField("phone")
    private String phone;

    @Schema(description = "密码")
    @TableField("password")
    private String password;

    @Schema(description = "用户昵称")
    @TableField("nick_name")
    private String nickName;

    @Schema(description = "用户类型")
    @TableField("user_type")
    private String userType;

    @Schema(description = "用户邮箱")
    @TableField("email")
    private String email;

    @Schema(description = "用户性别（0未知、1男 2女 ）")
    @TableField("gender")
    private Integer gender;

    @Schema(description = "头像地址")
    @TableField("avatar")
    private String avatar;

    @Schema(description = "帐号状态（0正常 1停用）")
    @TableField("status")
    private String status;

    @Schema(description = "最后登录IP")
    @TableField("login_ip")
    private String loginIp;

    @Schema(description = "最后登录时间")
    @TableField("login_date")
    private LocalDateTime loginDate;

    @Schema(description = "备注")
    @TableField("remark")
    private String remark;

    @Schema(description = "当用户在同一个微信开放平台账号下注册了多个公众号或小程序时，unionid可以用来标识同一个用户身份，即在这些公众号或小程序间，unionid是相同的，有助于跨应用识别用户。")
    @TableField("unionId")
    private String unionId;

    @Schema(description = "这是用户在每个公众号或小程序中的唯一标识")
    @TableField("openid")
    private String openid;
}
